package com.sinosoft.vaccinetoai.dao.mapper.business;

import com.sinosoft.vaccinetoai.dao.po.business.ChatRecord;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface ChatRecordMapper extends Mapper<ChatRecord> {

    /**
     * @Title: batchSave
     * @TitleExplain:
     * @Description: 批量插入
     * @param records 插入记录
     * @return
     * @version 1.0.3
     * @author xiazhihao
     */
    int batchSave(@Param("records") List<ChatRecord> records);

    /**
     * @Title: listByIO
     * @TitleExplain:
     * @Description:  根据条件查询
     * @param
     * @return List<ChatRecord
     * @version 1.0.3
     * @author xiazhihao
     */
    List<ChatRecord> listByIO(Object io);

    /**
     * @Title: update
     * @TitleExplain:
     * @Description: 更新
     * @param record 更新记录
     * @return
     * @version 1.0.3
     * @author xiazhihao
     */
    int update(@Param("record") ChatRecord record);

    /**
     * @Title: batchDelete
     * @TitleExplain:
     * @Description:  批量删除
     * @param ids 待删除的id集合
     * @return
     * @version 1.0.3
     * @author xiazhihao
     */
    int batchDeleteByChainId(@Param("ids") List<Long> ids);

    /**
     * @Title: batchDelete
     * @TitleExplain:
     * @Description:  批量删除
     * @param ids 待删除的id集合
     * @return
     * @version 1.0.3
     * @author xiazhihao
     */
    int batchDelete(@Param("ids") List<Long> ids);


}
